package com.Reporte_MasVendidos;

import java.io.InputStream;
import java.net.URL;

import android.graphics.drawable.Drawable;
import android.os.AsyncTask;

public class ImageDownloader extends AsyncTask<String, Void, Drawable> {

	@Override
	protected Drawable doInBackground(String... params) {
		try{
		    InputStream is = (InputStream) new URL(params[0]).getContent();
		    Drawable d = Drawable.createFromStream(is, "src");
		    return d;
	    }catch (Exception e) {
	    	System.out.println(e);
	    	return null;
	    }
	}	
	
	
}


